package com.example.hcmiu.englishforkid;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.Window;
import android.webkit.WebView;

public class HTMLActivity extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		requestWindowFeature(Window.FEATURE_NO_TITLE);
		setContentView(R.layout.activity_html);
		MainActivity.CurrentActivity = this;
		WebView w  = (WebView)findViewById(R.id.webView1);
		w.loadData(html2, "text/html", "UTF-8");
	}
	
	private static String html2="";
	
	public static void Show(String html) {	
		html2=html;
		Intent intent = new Intent(MainActivity.CurrentActivity,
				HTMLActivity.class);
		MainActivity.CurrentActivity.startActivity(intent);		
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.html, menu);
		return true;
	}

}
